package com.tc.erp.service;

import java.io.Serializable;
import java.util.List;

import org.hibernate.criterion.Criterion;

import com.tc.erp.common.hql.Sort;

public interface IBaseService <T, ID extends Serializable> {
	
    public long count(Criterion criterion);

    public T create(T entity);

    public boolean delete(ID id);

    public T get(ID id);

    public List<T> searchByPage(Criterion criterion, Sort sort, int offset, int pageSize);

    public T update(T entity);

}
